<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>RTW Report - rtGetNaN.c</title>
<link rel="stylesheet" type="text/css" href="rtwreport.css"></link><script language="JavaScript" type="text/javascript" src="rtwreport_utils.js"></script>
<SCRIPT type="text/javascript" language="JavaScript" src="slwebview.js"></SCRIPT>
<SCRIPT type="text/javascript" language="JavaScript" src="id_mapping.js"></SCRIPT>
<SCRIPT type="text/javascript" src="rtwannotate.js"></SCRIPT>
</head>
<body bgcolor="#eeeeee" onload="try {if (top) { if (top.rtwFileOnLoad) top.rtwFileOnLoad(window.document); else local_onload();}} catch(err) {};if (typeof rtwannotate === 'function') {rtwannotate('rtGetNaN_c_cov.xml');}">
<p>
<table border="0" cellspacing="0" cellpadding="6" width="100%%" height="100%%"><tr><td width="100%%" valign="top" bgcolor="#ffffff">
<h4>File: <a href="../rtGetNaN.c" target="rtwreport_document_frame" id="linkToText_plain">rtGetNaN.c</a></h4>
<pre id="RTWcode">
<span><a class="LN" name="1">    1   </a><font color="#992211">#</font><span class="PP">include</span> <font color="#992211">&quot;rtGetNaN.h&quot;</font>
</span><span><a class="LN" name="2">    2   </a><font color="#992211">#</font><span class="PP">define</span> NumBitsPerChar                 8U
</span><span><a class="LN" name="3">    3   </a>
</span><span><a class="LN" name="4">    4   </a><a href="rtwtypes_h.html#type_real_T" onclick="if (top) if (top.docHiliteMe) top.docHiliteMe(window, 'type_real_T');" target="_self"><font color="#1122aa">real_T</font></a> <a name="fcn_rtGetNaN">rtGetNaN</a>(<span class="DT">void</span>)
</span><span><a class="LN" name="5">    5   </a><b>{</b>
</span><span><a class="LN" name="6">    6   </a>  size_t bitsPerReal = <span class="KW">sizeof</span>(<a href="rtwtypes_h.html#type_real_T" onclick="if (top) if (top.docHiliteMe) top.docHiliteMe(window, 'type_real_T');" target="_self"><font color="#1122aa">real_T</font></a>) * (NumBitsPerChar);
</span><span><a class="LN" name="7">    7   </a>  <a href="rtwtypes_h.html#type_real_T" onclick="if (top) if (top.docHiliteMe) top.docHiliteMe(window, 'type_real_T');" target="_self"><font color="#1122aa">real_T</font></a> nan = 0.0;
</span><span><a class="LN" name="8">    8   </a>  <span class="KW">if</span> (bitsPerReal == 32U) <b>{</b>
</span><span><a class="LN" name="9">    9   </a>    nan = <a href="#fcn_rtGetNaNF" onclick="if (top) if (top.docHiliteMe) top.docHiliteMe(window, 'fcn_rtGetNaNF');" target="_self"><font color="#1122aa">rtGetNaNF</font></a>();
</span><span><a class="LN" name="10">   10   </a>  <b>}</b> <span class="KW">else</span> <b>{</b>
</span><span><a class="LN" name="11">   11   </a>    <span class="KW">union</span> <b>{</b>
</span><span><a class="LN" name="12">   12   </a>      <a href="rt_nonfinite_h.html#type_LittleEndianIEEEDouble" onclick="if (top) if (top.docHiliteMe) top.docHiliteMe(window, 'type_LittleEndianIEEEDouble');" target="_self"><font color="#1122aa">LittleEndianIEEEDouble</font></a> bitVal;
</span><span><a class="LN" name="13">   13   </a>      <a href="rtwtypes_h.html#type_real_T" onclick="if (top) if (top.docHiliteMe) top.docHiliteMe(window, 'type_real_T');" target="_self"><font color="#1122aa">real_T</font></a> fltVal;
</span><span><a class="LN" name="14">   14   </a>    <b>}</b> tmpVal;
</span><span><a class="LN" name="15">   15   </a>
</span><span><a class="LN" name="16">   16   </a>    tmpVal.bitVal.words.wordH = 0xFFF80000U;
</span><span><a class="LN" name="17">   17   </a>    tmpVal.bitVal.words.wordL = 0x00000000U;
</span><span><a class="LN" name="18">   18   </a>    nan = tmpVal.fltVal;
</span><span><a class="LN" name="19">   19   </a>  <b>}</b>
</span><span><a class="LN" name="20">   20   </a>
</span><span><a class="LN" name="21">   21   </a>  <span class="KW">return</span> nan;
</span><span><a class="LN" name="22">   22   </a><b>}</b>
</span><span><a class="LN" name="23">   23   </a>
</span><span><a class="LN" name="24">   24   </a><a href="rtwtypes_h.html#type_real32_T" onclick="if (top) if (top.docHiliteMe) top.docHiliteMe(window, 'type_real32_T');" target="_self"><font color="#1122aa">real32_T</font></a> <a name="fcn_rtGetNaNF">rtGetNaNF</a>(<span class="DT">void</span>)
</span><span><a class="LN" name="25">   25   </a><b>{</b>
</span><span><a class="LN" name="26">   26   </a>  <a href="rt_nonfinite_h.html#type_IEEESingle" onclick="if (top) if (top.docHiliteMe) top.docHiliteMe(window, 'type_IEEESingle');" target="_self"><font color="#1122aa">IEEESingle</font></a> nanF = <b>{</b> <b>{</b> 0 <b>}</b> <b>}</b>;
</span><span><a class="LN" name="27">   27   </a>
</span><span><a class="LN" name="28">   28   </a>  nanF.wordL.wordLuint = 0xFFC00000U;
</span><span><a class="LN" name="29">   29   </a>  <span class="KW">return</span> nanF.wordL.wordLreal;
</span><span><a class="LN" name="30">   30   </a><b>}</b>
</span><span><a class="LN" name="31">   31   </a>
</span></pre>
</td></tr></table>
</p>
</body>
</html>